NO_AT_BRIDGE: "1"
before_script:
- meson install -C mutter/build
+ - mkdir -m 700 $XDG_RUNTIME_DIR
script:
- dbus-run-session -- xvfb-run meson test -C build --no-rebuild
artifacts:
+data_builddir = meson.current_build_dir()
+
desktop_files = [
'org.gnome.Shell.desktop',
'org.gnome.Shell.Extensions.desktop',
custom_target('compile-schemas',
input: schema,
output: 'gschemas.compiled',
- command: [find_program('glib-compile-schemas'), meson.current_build_dir()],
+ command: [find_program('glib-compile-schemas'), data_builddir],
build_by_default: true)
}
function _spawnPerfHelper() {
- let path = Config.LIBEXECDIR;
+ let path = GLib.getenv('GNOME_SHELL_BUILDDIR') || Config.LIBEXECDIR;
let command = `${path}/gnome-shell-perf-helper`;
Util.trySpawnCommandLine(command);
}
+src_builddir = meson.current_build_dir()
+
service_data = configuration_data()
service_data.set('libexecdir', libexecdir)
script_data.set('PYTHON', python.full_path())
script_data.set('VERSION', meson.project_version())
-script_tools = ['gnome-shell-perf-tool']
+perf_tool = configure_file(
+ input: 'gnome-shell-perf-tool.in',
+ output: 'gnome-shell-perf-tool',
+ configuration: script_data,
+ install_dir: bindir
+)
if get_option('extensions_tool')
- script_tools += 'gnome-shell-extension-tool'
-endif
-
-foreach tool : script_tools
configure_file(
- input: tool + '.in',
- output: tool,
+ input: 'gnome-shell-extension-tool.in',
+ output: 'gnome-shell-extension-tool',
configuration: script_data,
install_dir: bindir
)
-endforeach
+endif
install_data('gnome-shell-extension-prefs',
install_dir: bindir
env: testenv,
workdir: meson.current_source_dir())
endforeach
+
+perf_tests = [
+ 'basic',
+]
+
+gvc_typelib_path = fs.parent(libgvc.get_variable('libgvc_gir')[1].full_path())
+libgvc_path = fs.parent(libgvc.get_variable('libgvc').full_path())
+
+perf_testenv = testenv
+perf_testenv.set('G_DEBUG', 'fatal-criticals')
+perf_testenv.set('G_MESSAGES_DEBUG', 'GNOME Shell')
+perf_testenv.set('GNOME_SHELL_DATADIR', data_builddir)
+perf_testenv.set('GNOME_SHELL_BUILDDIR', src_builddir)
+perf_testenv.append('GI_TYPELIB_PATH', gvc_typelib_path, separator: ':')
+perf_testenv.append('LD_LIBRARY_PATH', libgvc_path, separator: ':')
+
+foreach perf_test : perf_tests
+ test('perf-' + perf_test, dbus_runner,
+ args: [
+ perf_tool,
+ '--headless',
+ '--perf=@0@'.format(perf_test),
+ ],
+ env: perf_testenv,
+ )
+endforeach